import argparse

cmd_opt = argparse.ArgumentParser(description='Argparser for molecule vae')
cmd_opt.add_argument('-mode', default='gpu', help='cpu/gpu')
cmd_opt.add_argument('-save_dir', default='.', help='result output root')
cmd_opt.add_argument('-saved_model', default=None, help='start from existing model')
cmd_opt.add_argument('-grammar_file', help='grammar production rules')
cmd_opt.add_argument('-program_file', help='list of program strings')
cmd_opt.add_argument('-data_dump', help='location of h5 file')
cmd_opt.add_argument('-encoder_type', default='cnn', help='choose encoder from [cnn]')
cmd_opt.add_argument('-ae_type', default='vae', help='choose ae arch from [autoenc | vae]')
cmd_opt.add_argument('-rnn_type', default='gru', help='choose rnn cell from [gru | sru]')
cmd_opt.add_argument('-loss_type', default='perplexity', help='choose loss from [perplexity | binary]')
cmd_opt.add_argument('-max_decode_steps', type=int, default=80, help='maximum steps for making decoding decisions')
cmd_opt.add_argument('-batch_size', type=int, default=64, help='minibatch size')
cmd_opt.add_argument('-old_loss', type=int, default=0, help='use the wrong but working loss')
cmd_opt.add_argument('-latent_dim', type=int, default=56, help='encoding size')
cmd_opt.add_argument('-hidden', type=int, default=200, help='rnn size')
cmd_opt.add_argument('-dense', type=int, default=200, help='encoding dense size (before z_mean)')
cmd_opt.add_argument('-c1', type=int, default=7, help='conv1 size')
cmd_opt.add_argument('-c2', type=int, default=8, help='conv2 size')
cmd_opt.add_argument('-c3', type=int, default=9, help='conv3 size')
cmd_opt.add_argument('-min_len', type=int, default=1, help='min # states')
cmd_opt.add_argument('-max_len', type=int, default=5, help='max # states')
cmd_opt.add_argument('-data_gen_threads', type=int, help='number of threads for data generation')
cmd_opt.add_argument('-num_epochs', type=int, default=1, help='number of epochs')
cmd_opt.add_argument('-learning_rate', type=float, default=0.01, help='init learning_rate')
cmd_opt.add_argument('-prob_fix', type=float, default=0, help='numerical problem')
cmd_opt.add_argument('-kl_coeff', type=float, default=1, help='coefficient for kl divergence used in vae')
cmd_opt.add_argument('-eps_std', type=float, default=0.01, help='the standard deviation used in reparameterization tric')

cmd_args, _ = cmd_opt.parse_known_args()
